<template>
	<div class="project">
		<div class="right_header" :style='{"background":this.$store.getters.theme[5]}'>
			<div class="listName" :style='{"color":this.$store.getters.theme[6]}'> <i class="icon iconfont">&#xe7d8;</i>
				当前位置/授权管理/
				<span>工程管理</span>
			</div>
		</div>
		<div class="right_content">
			<el-button type="primary" @click="moudleShowFun()">
				<i class="el-icon-edit"></i>&nbsp
				添加工程
			</el-button>
			<el-tree
			  :data="data2"
			  :props="defaultProps"
			  node-key="id"
			  default-expand-all
			  :expand-on-click-node="false"
			  :render-content="renderContent">
			</el-tree>
		</div>
		<div class="projectshade" v-show="moudleShow">
			<div class="projectChoose">
				<div class="vicp-close"  @click="moudleShow=false"> <i class="el-icon-close vicp-icon4"></i>
				</div>
				<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
					<h5>添加工程</h5>
					<el-form-item label="排序ID" prop="moudleId">
						<el-input v-model.number="ruleForm.moudleId"></el-input>
					</el-form-item>
					<el-form-item label="工程名称" prop="moudleName">
						<el-input v-model="ruleForm.moudleName"></el-input>
					</el-form-item>
					<el-form-item label="工程URL" prop="moudleUrl">
						<el-input v-model="ruleForm.moudleUrl"></el-input>
					</el-form-item>
					<el-form-item label="工程描述" prop="moudleIntro">
						<el-input type="textarea" v-model="ruleForm.moudleIntro"></el-input>
					</el-form-item>
					<el-form-item>
						<el-button type="primary" @click="submitForm('ruleForm')">立即创建</el-button>
						<el-button @click="resetForm('ruleForm')">重置</el-button>
					</el-form-item>
				</el-form>
			</div>
		</div>
		<div class="revampshade" v-show="revampShow">
			<div class="revampChoose">
				<div class="vicp-close"  @click="revampShow=false"> <i class="el-icon-close vicp-icon4"></i>
				</div>
				<el-form :model="revampForm" :rules="revampRules" ref="revampForm" label-width="100px" class="demo-ruleForm">
					<h5>修改工程</h5>
					<el-form-item label="排序ID" prop="revampSortId">
						<el-input v-model.number="revampForm.revampSortId"></el-input>
					</el-form-item>
					<el-form-item label="工程URL" prop="moudleUrl">
						<el-input v-model="revampForm.revampUrl"></el-input>
					</el-form-item>
					<el-form-item label="工程名称" prop="revampName">
						<el-input v-model="revampForm.revampName"></el-input>
					</el-form-item>
					<el-form-item label="工程描述" prop="moudleIntro">
						<el-input type="textarea" v-model="revampForm.revampIntro"></el-input>
					</el-form-item>
					<el-form-item>
						<el-button type="primary" @click="revampSubmit('revampForm')">立即修改</el-button>
						<el-button @click="resetRevamp('revampForm')">重置</el-button>
					</el-form-item>
				</el-form>
			</div>
		</div>
	</div>
</template>
<style lang="stylus" rel="stylesheet/stylus" src="./project.styl"></style>
<script src="./project.js"></script>